import { request, config } from 'utils'

const { api } = config
const {
  companyChargeTypeAdd,
  companyChargeTypeAllBrif,
  companyChargeTypeDel,
  companyChargeTypeMultiDel,
  companyChargeTypeEdit,
  companyChargeTypeGet,
  companyChargeTypeList,
  companyChargeTypeListBrif,
} = api

export async function add (params) {
  return request({
    url: companyChargeTypeAdd,
    method: 'post',
    data: params,
  })
}
export async function allbrif (params) {
  return request({
    url: companyChargeTypeAllBrif,
    method: 'post',
    data: params,
  })
}
export async function del (params) {
  return request({
    url: companyChargeTypeDel,
    method: 'delete',
    data: params,
  })
}
export async function delall (params) {
  return request({
    url: companyChargeTypeMultiDel,
    method: 'delete',
    data: params,
  })
}
export async function edit (params) {
  return request({
    url: companyChargeTypeEdit,
    method: 'put',
    data: params,
  })
}
export async function get (params) {
  return request({
    url: companyChargeTypeGet,
    method: 'put',
    data: params,
  })
}
export async function list (params) {
  return request({
    url: companyChargeTypeList,
    method: 'put',
    data: params,
  })
}
export async function listbrif (params) {
  return request({
    url: companyChargeTypeListBrif,
    method: 'post',
    data: params,
  })
}
